import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
        home: Scaffold(
          appBar: AppBar(
            title: const Text('demo'),
          ),
          body: const HomeContent(),
        ),
        theme: ThemeData(primarySwatch: Colors.yellow));
  }
}

class HomeContent extends StatelessWidget {
  const HomeContent({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Center(
      child: Container(
        width: 300.0,
        height: 300.0,
        // const EdgeInsets.all(30),
        padding: const EdgeInsets.fromLTRB(120, 10, 30, 80),
        // transform: Matrix4.translationValues(100, 20, 10),
        transform: Matrix4.rotationY(0.3),
        alignment: Alignment.bottomCenter,
        decoration: BoxDecoration(
            color: Colors.red[50],
            // borderRadius: BorderRadius.all(Radius.circular(150)),
            border: Border.all(color: Colors.yellow, width: 2.0)),
        child: const Text(
          '这是一段很长的数据展示这是一段很长的数据展示这是一段很长的数据展示这是一段很长的数据展示',
          textAlign: TextAlign.center,
          maxLines: 2,
          textScaleFactor: 1.2,
          overflow: TextOverflow.ellipsis,
          style: TextStyle(
              fontSize: 20.0,
              color: Colors.blue,
              decoration: TextDecoration.lineThrough,
              decorationColor: Colors.red,
              decorationStyle: TextDecorationStyle.dashed),
        ),
      ),
    );
  }
}

class demoContent extends StatelessWidget {
  const demoContent({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return AboutListTile(
      child: Text('About 老孟程序员'),
    );
  }
}
